home *** CD-ROM | disk | FTP | other *** search
- Path: news.panther.net!nemesis!hammy!not-for-mail
- From: gordon@sneaky.lerctr.org (Gordon Burditt)
- Newsgroups: comp.lang.c
- Subject: Re: TIME.H for the year 2000?
- Date: 2 Apr 1996 22:55:19 -0600
- Organization: What organization?
- Message-ID: <4jt0bn$1u2@hammy.lonestar.org>
- References: <3161A8FC.53AC@dial.cic.net>
- NNTP-Posting-Host: news.hammy.lonestar.org
-
- >From reading up on the functions in time.h, it looks like it will only
- >handle years < 2000. Is this right?
-
- No.
-
- >If so, can someone direct me to any
- >routines that have been written to take into account years >= 2000?
-
- The tm_year element of a struct tm contains the year - 1900.
- The type of tm_year is int. It should be able to handle years
- up to 34667 (value in tm_year: 32767). On machines where ints
- are 32 bits, this handles years up to over 2 billion. tm_year
- contains the year-1900, *NOT* the last two digits of the year.
-
- One traditional representation of time_t becomes signed in January 2038.
- Hopefully we will have gone to 64-bit time_t's by then.
-
- Gordon L. Burditt
- sneaky.lerctr.org!gordon
-